package com.design.mall;

/**
 * 选择具体策略算法
 *
 * @author by liuxin
 * @version 0.1
 */
public class CashContext {

    CashRegister cashRegister;

    public CashContext(CashRegister cashRegister) {
        this.cashRegister = cashRegister;
    }

    public double pay(double money) {
        return cashRegister.acceptCash(money);
    }
}
